package com.sqjw.demo.service;

import com.sqjw.demo.entity.User;
import com.sqjw.demo.mapper.UserMapper;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author zhaoxingwu
 */
@Component
public class UserService {

    @Resource
    private UserMapper userMapper;

    public void query() {
        List<User> result = userMapper.query();
        User user = userMapper.selectById(1);
        System.out.println(result);
    }
}
